<style type='text/css'>
	.goods-list a {
		position: relative; 
	}
	.goods-list span  {
	float:right;margin-right:20px;
	 
	}
</style>

{php $totals = m('goods')->getTotals()}
{ifp 'goods'}
<div class='menu-header'><i class="menu-icon fa {if $_GPC['r']=='goods'||$_GPC['r']=='goods.category'||$_GPC['r']=='goods.group'||$_GPC['r']=='goods.label'}fa-caret-down{else}fa-caret-right{/if}"></i>商品管理</div>
<ul class='goods-list' {if $_GPC['r']=='goods'||$_GPC['r']=='goods.category'||$_GPC['r']=='goods.group'||$_GPC['r']=='goods.label'}style="display: block;"{/if}>
    <li {if $_GPC['goodsfrom'] == 'sale'} class="active" {/if}><a href="{php echo webUrl('goods',array('goodsfrom'=>'sale'))}">出售中<span>{$totals['sale']}</span></a></li>
     <li {if $_GPC['goodsfrom'] == 'out'} class="active" {/if}><a href="{php echo webUrl('goods',array('goodsfrom'=>'out'))}">已售罄<span  class='text-danger'>{$totals['out']}</span></a></li>
    <li {if $_GPC['goodsfrom'] == 'stock'} class="active" {/if}><a href="{php echo webUrl('goods',array('goodsfrom'=>'stock'))}">仓库中<span>{$totals['stock']}</span></a></li>
    <li {if $_GPC['goodsfrom'] == 'cycle'} class="active" {/if}><a href="{php echo webUrl('goods',array('goodsfrom'=>'cycle'))}">回收站<span  class='text-default'>{$totals['cycle']}</span></a></li>
     {ifp 'goods.category'}<li {if $_W['action'] == 'goods.category'} class="active" {/if}><a href="{php echo webUrl('goods/category')}">商品分类</a></li>{/if}
    {ifp 'goods.group'}<li {if $_GPC['r'] == 'goods.group' || $_GPC['r'] == 'goods.group.edit'}class="active" {/if}><a href="{php echo webUrl('goods/group')}">商品组</a></li>{/if}
    <li {if $_W['action'] == 'goods.label'} class="active" {/if}><a href="{php echo webUrl('goods/label')}">标签管理</a></li>
</ul>
{/if}

{if com('virtual')}
{ifp 'goods.virtual.temp|goods.virtual.category|goods.virtual.data'}
<div class='menu-header'><i class="menu-icon fa {if $_GPC['r']=='goods.virtual.temp'||$_GPC['r']=='goods.virtual.category'||$_GPC['r']=='goods.virtual.data'}fa-caret-down{else}fa-caret-right{/if}"></i>虚拟卡密</div>
<ul {if $_GPC['r']=='goods.virtual.temp'||$_GPC['r']=='goods.virtual.category'||$_GPC['r']=='goods.virtual.data'}style="display: block;"{/if}>
    {ifp 'goods.virtual.temp'}<li {if $_W['action'] == 'goods.virtual.temp' ||$_W['action'] == 'goods.virtual.data'} class="active" {/if}><a href="{php echo webUrl('goods/virtual/temp')}">虚拟卡密</a></li>{/if}
    {ifp 'goods.virtual.category'}<li {if $_W['action'] == 'goods.virtual.category'} class="active" {/if}><a href="{php echo webUrl('goods/virtual/category')}">卡密分类</a></li>	{/if}
    {ifp 'goods.virtual.set'}<li {if $_W['action'] == 'goods.virtual.set'} class="active" {/if}><a href="{php echo webUrl('goods/virtual/set')}">设置</a></li>	{/if}
</ul>
{/if}
{/if}

